package org.slf4j.impl;

import com.sweet.logging.factory.SweetLoggerFactory;
import org.slf4j.ILoggerFactory;
import org.slf4j.spi.LoggerFactoryBinder;

/**
 * 按照约定 StaticLoggerBinder 类由 SLF4J API 自动查找，实现注入
 *
 * @author xiexiaofeng
 * @version 1.0     2017年09月08日  10点16分
 */
public class StaticLoggerBinder implements LoggerFactoryBinder
{

    private static final StaticLoggerBinder SINGLETON = new StaticLoggerBinder();

    private static final String loggerFactoryClassStr = SweetLoggerFactory.class.getName();

    public static final StaticLoggerBinder getSingleton()
    {
        return SINGLETON;
    }

    public ILoggerFactory getLoggerFactory()
    {
        return new SweetLoggerFactory();
    }

    public String getLoggerFactoryClassStr()
    {
        return loggerFactoryClassStr;
    }

}
